SQL: Using a column created in the SELECT in the WHERE CLAUSE
Can I use a column in the WHERE clause that I created with ‘AS’ in the WHERE clause. I have tried and SQL tells me that the column is not in the table? Thanks, Ray
Answer Question
| July 9, 2008 7:26 PM
SELECT statement, SQL, SQL statements
Can I use a column in the WHERE clause that I created with ‘AS’ in the WHERE clause. I have tried and SQL tells me that the column is not in the table? Thanks, Ray
Looking for a database name query in SQL
Is there a query in SQL that could return me the name of a database, or whether it is connected to SQL Server or Oracle?
Answer Question
| July 4, 2008 5:49 PM
Database, Query, SQL, SQL Query, SQL Server
Is there a query in SQL that could return me the name of a database, or whether it is connected to SQL Server or Oracle?
Trim 2 right characters in a string
In sql how would I trim off the 2 right characters in a variable length string
Answer Question
| June 30, 2008 8:13 PM
SQL, Strings
In sql how would I trim off the 2 right characters in a variable length string
excel report from rpg or sql
How do I produce an excel report via RPG or SQL inside an RPG program.
Answer Question
| November 25, 2010 6:07 PM
Microsoft Excel, RPG, SQL
How do I produce an excel report via RPG or SQL inside an RPG program.
Rookie Prolem: Using DIGITS() function on an INTEGER value
Folk, here’s my problem: My SQL knowledge is weak, but I know the basics based on RDBMS work. I have an SQL statement that contains the following statement: SUBSTR(DIGITS(b.SIN),2,9) My output looks like this: “.&114172661″ (Quotes added for clarity. The SIN is a 9 digit INTEGER (114172661). It’s the first two ‘characters’ (“.&”) that have [...]
Answer Question
| July 7, 2008 2:23 PM
DIGITS, SQL, SQL statements
Folk, here’s my problem: My SQL knowledge is weak, but I know the basics based on RDBMS work. I have an SQL statement that contains the following statement: SUBSTR(DIGITS(b.SIN),2,9) My output looks like this: “.&114172661″ (Quotes added for clarity. The SIN is a 9 digit INTEGER (114172661). It’s the first two ‘characters’ (“.&”) that have [...]
SQL Fetch
I an joing tow files with inner join. I want all the fields from the first file and only two fields from the other file. I defined an external DS for the first file then included that DS in another DS with the two fields from the other file but program will no compile. Will [...]
Answer Question
| April 28, 2010 8:30 PM
Fetch, Join logical files, SQL
I an joing tow files with inner join. I want all the fields from the first file and only two fields from the other file. I defined an external DS for the first file then included that DS in another DS with the two fields from the other file but program will no compile. Will [...]
Finding the appropriate settings for copying tables within databases
I have a table in a database that has 104456 records. I would like to copy the data to another table within that database. When I execute the command “insert into ChangeInsuranceTxnHistory select * from ChangeInsuranceTxn”, the following error occurs: “Could not allocate space for object ‘ChangeInsuranceTxnHistory’ in database ‘CC_CCAR’ because the ‘PRIMARY’ filegroup is [...]
Answer Question
| June 18, 2008 5:14 PM
Copy error, Database issues, SQL, SQL error messages
I have a table in a database that has 104456 records. I would like to copy the data to another table within that database. When I execute the command “insert into ChangeInsuranceTxnHistory select * from ChangeInsuranceTxn”, the following error occurs: “Could not allocate space for object ‘ChangeInsuranceTxnHistory’ in database ‘CC_CCAR’ because the ‘PRIMARY’ filegroup is [...]
rpg sql
I am using dynamic sql in an rpgle pgm. This pgm is called from 2 different menu options. When I take the 2nd option, everything works fine. I exit out of that option and take the first option. Everything is still work fine. I exit the first option and go back to the 2nd option [...]
Answer Question
| April 27, 2010 4:33 PM
Dynamic SQL, RPGLE, SQL
I am using dynamic sql in an rpgle pgm. This pgm is called from 2 different menu options. When I take the 2nd option, everything works fine. I exit out of that option and take the first option. Everything is still work fine. I exit the first option and go back to the 2nd option [...]
Using co-related queries in SQL
How do you use co-related queries in SQL and why would they be useful? Is there any effect on performance when executing a co-related query?
Answer Question
| June 19, 2008 3:46 PM
Co-related queries, Query, SQL, SQL Query
How do you use co-related queries in SQL and why would they be useful? Is there any effect on performance when executing a co-related query?
T-SQL how to identfiy tables that have dulicate roaws
I have a MS 2000 SQL server. How can I search the db and indentify the tables that have duplicate raws. Thanks
Answer Question
| June 18, 2008 9:44 PM
SQL, SQL Server 2000, T/SQL
I have a MS 2000 SQL server. How can I search the db and indentify the tables that have duplicate raws. Thanks
Seeking Help with SQL SUBSTR Function using Host Variables in COBOL
Hello All I am currently on version V5R2 and I am trying to make a COBOL program produce some parsed fields from one large field. I have trying to use host variables for al three arguments in the SUBSTR function. The SQL compiler will take a host variable as argument number one but not for [...]
Answer Question
| April 28, 2010 8:52 PM
AS/400, COBOL, SQL, SUBSTR, V5R2
Hello All I am currently on version V5R2 and I am trying to make a COBOL program produce some parsed fields from one large field. I have trying to use host variables for al three arguments in the SUBSTR function. The SQL compiler will take a host variable as argument number one but not for [...]
Executing a Stored procedure using Excel Macro
I am an amateur in SQL programming. Could you please tell me how to execute a Stored procedure using Excel Macro (VBA Programming) and then save the record set into different Excel sheets?
Answer Question
| June 13, 2008 6:36 PM
Excel macros, SQL, Stored Procedures, VBA
I am an amateur in SQL programming. Could you please tell me how to execute a Stored procedure using Excel Macro (VBA Programming) and then save the record set into different Excel sheets?
Concentrate more than two fields together into one field in SQL
Say I have 3 columns: 1st name, middle name and last name. How do I merge the 3 columns into one column yet separate the content with commas?
Answer Question
| April 19, 2013 2:55 PM
Concatenate, CSV, SQL, SQL Server
Say I have 3 columns: 1st name, middle name and last name. How do I merge the 3 columns into one column yet separate the content with commas?
AR server
we r using the AR server 7.0 the backend database is sql 2000 under window platform, so now if I need to change the database table format to CLOB then, any one could tell me what is the format of changing the database format, I mean the table format to In-row and Out-row method. Could [...]
Answer Question
| September 20, 2008 7:51 AM
AR server, CLOB, SQL, SQL Server 2000
we r using the AR server 7.0 the backend database is sql 2000 under window platform, so now if I need to change the database table format to CLOB then, any one could tell me what is the format of changing the database format, I mean the table format to In-row and Out-row method. Could [...]
msforeachdb
Could not locate entry in sysdatabases for database, when using msforeachdb
Answer Question
| June 11, 2008 4:22 PM
SQL, SQL Database
Could not locate entry in sysdatabases for database, when using msforeachdb
Copy Attachments to Folder
Anyone have a lotusscript to copy attachments to a folder? Also need to extract to excel a view but right now i think i can handle that with NotesSQL ODBC. The attachments part is buging me the most. This is not a mail system…. We have a database setup for document approvals. Lotus Domino 6.5
Answer Question
| June 13, 2008 1:29 PM
Domino, Lotus Domino, Lotus Notes 6.x, LotusScript, ODBC, SQL
Anyone have a lotusscript to copy attachments to a folder? Also need to extract to excel a view but right now i think i can handle that with NotesSQL ODBC. The attachments part is buging me the most. This is not a mail system…. We have a database setup for document approvals. Lotus Domino 6.5
Is it possible convert a mainframe COBOL program to read DB2 data on the mainframe and Oracle data on a server?
I have a mainframe batch COBOL program that reads DB2 data. One of the tables is accessed via a singleton SELECT. The table is being moved to an Oracle database on a Unix server. How do I change the program to be able to access the data in Oracle? Are there different ways to it? [...]
Answer Question
| September 23, 2009 6:37 PM
COBOL, DB2, Mainframe, Oracle, SQL, Unix
I have a mainframe batch COBOL program that reads DB2 data. One of the tables is accessed via a singleton SELECT. The table is being moved to an Oracle database on a Unix server. How do I change the program to be able to access the data in Oracle? Are there different ways to it? [...]
DSNTEP2 output problem
DSNTEP2 (aka SPUFI in batch) is causing problems for my extract JCL. How do you get rid of the SPUFI-like column headers from the output datafile produced by DSNTEP2? I don’t have ANY experience with REXX, so an example would be appreciated. Jon
Answer Question
| December 5, 2011 4:49 PM
DB2, DSNTEP2, JCL, REXX, SQL
DSNTEP2 (aka SPUFI in batch) is causing problems for my extract JCL. How do you get rid of the SPUFI-like column headers from the output datafile produced by DSNTEP2? I don’t have ANY experience with REXX, so an example would be appreciated. Jon
Can I use filler to skip a column in a csv file on SQL*LOADER rel 8.0.6.3.0
We are running Oracle E-business suite 11.5.10.2 on db 9i but when I execute sql*loader it gives me version 8.0.6.3.0. Is the key word FILLER available for me to use to skip unwanted columns in a comma delimited input file? I know FILLER became a key work in 9i – is that the db 9i? [...]
Answer Question
| October 18, 2010 4:47 PM
CSV, CSV input file, Oracle E-Business Suite, SQL
We are running Oracle E-business suite 11.5.10.2 on db 9i but when I execute sql*loader it gives me version 8.0.6.3.0. Is the key word FILLER available for me to use to skip unwanted columns in a comma delimited input file? I know FILLER became a key work in 9i – is that the db 9i? [...]
SQL SERVER REPORTING SERVICES
can anyone explain what is presentation delivery utilizing reporting services?
Answer Question
| June 12, 2008 3:43 PM
SQL, SQL Server, SSRS 2005
can anyone explain what is presentation delivery utilizing reporting services?





