SQL Statements Questions and Answers

Recent IT Questions

21 - 38 of 38
<<PREVIOUS 1|2 NEXT>>

ALTER INDEX statement

'ALTER INDEX ' || C_Indices.INDEX_NAME ||' REBUILD '; 'ALTER INDEX ' || C_Indices.INDEX_NAME || ' REBUILD ONLINE COMPUTE STATISTICS'; In my stored procedure , i am reconstructing or you can say re-building the tables and table name is the input parameter to the procedure. In middle of the code ,...

View Answer   |  Dec 16 2008  12:54 AM GMT
Oracle development, Oracle SQL, Oracle stored procedures
asked by Shaksing

  5 pts.

PL/SQL: How to handle OUT Parameter during INSERT

HI Experts, I have a OUT parameter in my procedure(whihc performs INSERT data into a table),how to handle this OUT parameter (primary key of table) -- Will Insert statement inside the PL/SQL block should include this parameter or we should use SELECT stm after Insert to add this attribute ,i am...

View Answer   |  Dec 15 2008  6:56 AM GMT
PL/SQL, SELECT statement, SQL statements
asked by Inprise

  525 pts.

IF ELSE in SQL Server stored procedure

i am using this code which is giving error. if (@report_type = 'CM') Begin Select distinct Region,sum(ClientCount) as ClientTotal Into #NewTemp From ( End else if (@report_type = 'AM' ) Begin ( Select distinct Region,Area,sum(ClientCount) as ClientTotal Into...

asked by Rrj1

  5 pts.

How to save the output from an SQL select statement to a spool file

Please can someone tell me how I can save the output from an SQL select statement to a spool file. Thanks, Tom

View Answer   |  Dec 12 2008  10:23 AM GMT
SQL, Spool files, SELECT statement
asked by Tomotsk

  45 pts.

SQL statement exceeding 2000 characters in Oracle Graphics Builder

In Developer 6i Graphics Builder, i am not able to write query exceeding 2000 character. i think it is restriction in this version. If I want to write query exceeding 2000 then please suggest me what to do.

View Answer   |  Dec 10 2008  10:27 AM GMT
SQL, Oracle development, SQL statements
asked by 440638

  45 pts.

SQL select

SELECT obj.object_type FROM apps.opt_log_issue log, discov.opt_changed_database_objects obj WHERE --(UPPER(log.resolution(+)) like '%'||obj.object_name||'%' -- and trunc(log.resolution_date(+)) - trunc(to_date(substr(obj.last_ddl_time,1,11),'dd-mon-yy')) <=5 -- and...

View Answer   |  Nov 28 2008  11:09 PM GMT
Oracle development, Oracle SQL, SELECT statement
asked by QAQA

  65 pts.

Setting and establishing a default connection before a SQL statement

Is it necessary to establish a connection and set it to the default before and after the execution of any SQL statement? I am develolping a multi-user system with 10 users in Visual Basic 6.0 with SQL Server 2000 and i need to know this for my setup.

View Answer   |  Oct 15 2008  8:14 PM GMT
SQL Server 2000, Visual Basic 6, SQL statements
asked by SQL Server Ask the Experts

  2445 pts.

Tuning a simple SQL statement in SQL Server 2005

How would I tune a simple SQL statement, like "SELECT @eno = eno FROM emp WHERE dno = @dno," in SQL Server 2005?

View Answer   |  Oct 13 2008  6:47 PM GMT
SQL Server 2005, SQL Server performance, SQL statements
asked by SQL Server Ask the Experts

  2445 pts.

Checking for a transaction isolation level in SQL Server Profiler

How could I check if a transaction isolation level is being used for a LINQ to a SQL statement in SQL Server Profiler?

View Answer   |  Sep 19 2008  4:41 PM GMT
LINQ, SQL statements, Isolation level
asked by SQL Server Ask the Experts

  2445 pts.

can a file be loaded from an embedded sql statement?

can a file be loaded from an embedded sql statement? I want to use the file that was loaded to display the data in a subfile.

View Answer   |  Aug 28 2008  6:28 PM GMT
SQL, SQL statements
asked by Cansler

  50 pts.

Display number of records effected by update/delete/insert SQL statement

Whenever I carry out an insert/delete/update SQL statment I would like to show how many records have been effected in the Run History box. Sometimes this does work OK but not always. Need to know what if anything if is controlling the display of this information.

View Answer   |  Aug 4 2008  2:50 PM GMT
SQL, SQL statements
asked by TheTunnel

  5 pts.

What is the best way to execute SQL statements in a CL program.

What is the best way to execute SQL statements in a CL program. We can run sql statements in a RPG program. I want to delete some records from a file using the sql delete statement then organize it.

View Answer   |  Jul 17 2008  5:24 PM GMT
CLP, CL, SQL statements
asked by SHhand

  15 pts.

Explaining certain functions in SQL

What do the MOD function and the ROUND function do in SQL?

View Answer   |  Jul 8 2008  3:48 PM GMT
SQL, Functions, SQL statements
asked by SQL Server Ask the Experts

  2445 pts.

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

View Answer   |  Jul 7 2008  7:26 PM GMT
SQL, SQL statements, SELECT statement
asked by RayT

  30 pts.

Excluding Data Usin NOT IN

I'm trying to export data from a sql table into sql reporter. The information I'm trying to retrieve is information regarding permissions (this is audit stuff). The problem is, there are spaces (and always a different amount of spaces) between the user and the permissions; for example: Type ...

asked by Jerzdevs

  10 pts.

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)....

View Answer   |  Jun 23 2008  2:23 PM GMT
SQL, SQL statements, DIGITS
asked by Jonty Walker

  105 pts.

Is there a way to partial field (or substring) a DESCR254_MIXED (long character field) in a SQL statement?

Is there a way to partial field (or substring) a DESCR254_MIXED (long character field) in a SQL statement? Have tried the following, which do not work: column descr254_mixed format A30 set wrap off select descr254_mixed from PS REQ_LINE SELECT left(descr254_mixed, 20) from PS_REQ_LINE

View Answer   |  Jun 9 2008  4:50 PM GMT
SQL, AS/400 and SQL, SQL statements
asked by SQL Server Ask the Experts

  2445 pts.

SQL Text Match on Character Stream (wildcards)

I need to match a text field on zero or more characters. If available, the 'or more' characters need to be in a specific sequence. The % wildcard doesn't quite cut it. For instance, I need to match the name with 'm', 'ma' or 'mar' (but no other character combinations). Is this possible?

View Answer   |  May 23 2008  0:58 AM GMT
SQL, SQL statements, Wildcards
asked by Ohreallyus

  5 pts.

21 - 38 of 38
<<PREVIOUS 1|2 NEXT>>