• Embedded SQL in an RPG FREE program

    I am developing an on-line screen program, where the user can select a view of the data from a list of "views". This is my first crack at embedded SQL, Basically i issue the Prepare, declar the c1 scroll cursor, and then open c1, and then do the fetch. At this point I am loading the subfile. First...

    Merts30 pointsBadges:
  • Subtracting two numbers

    Hi Using SQL, how can I subtract two values for the same parameter received at different times say 1am and 1:30am so sql to do value(1:30am)-value(1am)=? Regards

    Shajju10 pointsBadges:
  • SQL – Pass the result of the first query as the second query select column name

    I want to pass the result of a sql query as the column name in another query eg. (note there will be a single result for the first query) SELECT CASE WHEN fld_type1 = 'A' THEN 'VAL_ALPHA1' WHEN fld_type1 = 'D' THEN 'VAL_DATE1' ELSE 'VAL_NUM1' END AS FIELDNAME FROM TABLE1 I want the result of the...

    Chris12325 pointsBadges:
  • SQL Data Types Conversions

    I'm new to SQL. Anyone have a good example or link of converting from one data type to another. We are converting from an iSeries (AS400) to SQL-based ERP solution and we are having some difficulty with how to get data from numeric fields to date or "numeric" data types. Our iSeries ERP solution...

    MikeBaker5 pointsBadges:
  • How to run SQL script with parameters in CL

    I have to call an sql script with parameters from an existing cl program that runs daily (in batch). If I call it from the cl program, it is giving me this error "Pointer not set for referenced location referenced".

    Ara5 pointsBadges:
  • SQL query to list databases that have a given table

    Hi all I need your help for creating some SQL query that returns the names of all databases that have a given table name. Ex. I'd like to run this query against the master database and search for all databases that have a table called "customers". Is it possible to do this, if yes how? Thanks in...

    alessandro.panzetta9,725 pointsBadges:
  • Using the return value of a SQL Restore script

    I am trying to use the return value of a SQL Restore script executed with SQLCMD, so that my batch script can report on the succes or failure of the restore. I am having difficulty getting the script to return the result of the backup or restore process. Do you have any suggestions? The follwoing...

    SQL Server Ask the Experts2,585 pointsBadges:
  • Reading an unknown file in RPG

    Hi All, I am working on a DBU like utility which will provide a maintainance screen for each file. I need to read the file in an rpg program but i dont know the program name till runtime. I can't declare the file in F specs as i dont know the file name. SQL is very bothering and is very heavy for...

    Detuli15 pointsBadges:
  • table row values for column headers

    Hi. I have two tables in a simple database: Prices ID (int, identity, PK) Year (smallint - year of value) Quarter (smallint - year quarter 1-4) Area (smallint - FK to Areas.ID) Index (float) Areas ID (int, identity, PK) Name (varchar) So, as you can see, the Prices table contains price information...

    Snowbunny5 pointsBadges:
  • pass variable from Foreach loop to stored Procedure parameters

    in control flow I run "Execute SQL Task" to retrive array variables like State Code ('AR', 'WI', .. et). Then I run ForeEach Loop Container and pass global variable gv_StateCode into Data Flow, where I run stored proc with one parameter in "OLE DB Source" (like exec sp_StProcname ?) and i assign...

    IG194410 pointsBadges:
  • SQL Server 2005 Select Multiple views or Tables

    in SQL 2000 it was easy to cntl-right-click and select multiple views, stored procedures or tables and generate one script which could be changed (using SQL Analyzer) to create new objects (search and replace text) with different names. This was a big time saver but I don't know how to do that in...

    SapwizSAP5 pointsBadges:
  • SQL relational database

    A relational database contains the following tables: Employee (EmployeeNo, EmployeeName, DateOfBirth, JobDescription,DeptNo) Project (ProjectNo, ProjectName, Location)Assignment (EmployeeNo, ProjectNo, Role-in-Project)Formulate the following using SQL:i. Find the names of all employees assigned to...

    Lystra10 pointsBadges:
  • Custom alert messages with SQL

    sql custom messages, how to put a message box if value entered is already taken? and if value entered does not exist?

    Yosbeeebajay10 pointsBadges:
  • Oracle Forms 6i Database Objects

    I have problem that Forms 6i does not see packages stored on Database with Dynamic SQL code on it. When I open Forms Designer it does see Database Objects at the bottom but with running the forms it gives and error that does see sys. dba_sql. Thank you

    Oikhleif30 pointsBadges:
  • tell me why I’m getting the message “The multi-part identifier “134062-DB1.netFORUMSTaging.dbo.Individual.individualKey” could not be bound”

    I'm trying to process this SQL statement select cxa_cst_key, cxa_key, cxa_key from [134062-DB1].netFORUMSTaging.dbo.Individual LEFT JOIN dbo.co_customer_x_address ON [134062-DB1].netFORUMSTaging.dbo.Individual.individualKey = co_customer_x_address.cxa_cst_key where delete_flag = 0 and source not in...

    Calvin606165 pointsBadges:
  • Crystal Reports XI – Showing records when setting criteria

    Goal: To show all customer orders. Along with those orders, I want to show all related notes on the progress for filling those orders. Problem: Some orders have no notes. When I set the criteria to show all orders and to show the notes, only orders with notes now appear in the report. Question: Is...

    Hritguy5 pointsBadges:
  • Upgrading Forms30 on Oracle 7.0

    I am upgrading Forms30 on Oracle 7.0 to Oracle 10g First, I am upgrading to Oracle forms 6i using Forms compiler and facing these problems I. converting language on display item. (it doesn't show the right language on display item and headers) 2. key mapping function. 3. I need script so I can...

    Oikhleif30 pointsBadges:
  • Looping Queries in Oracle using data from SQL Server

    I have a table of entries from SQL server called PID. Each of this entry should follow the following select * from HR.TABLES a START WITH a.SID = '0' CONNECT BY PRIOR a.parentid = a.sid' Where I have '0' in the query above, should take all the values from PID. Is there a easy way to write this? or...

    Sreedhar775 pointsBadges:
  • Embed date in SQLBase unload filename

    I have a scheduled task to runs a backup script each night using a program called SQL_Talk for Windows version 9.0.1. I am using this program to unload a SQLBase database each night for backup purposes. I have a separate script for each night of the week. Below is the Monday script: set server...

    Flame14,925 pointsBadges:
  • Slowdown in SQL Restore on SQL Server 2000

    We are running SQL Server 2000 on Windows 2000 Server SP4, and our SQL Restore takes at least 10 minutes to launch in Enterprise Manager. We had to roll back after an upgrade, and we find that when selecting "Restore Database", Enterprise Manager runs remarkably slow. I'm sure we could run the...

    SQL Server Ask the Experts2,585 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following