Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by bunmiA

  1. bunmiA

    Crystal Reports Viewer: Server has not yet opened

    I am running crystal reports using a VB reports scheduler. This scheduler has been working fine for years with SQL Databases. I have now added a report which uses a Remedy ODBC as a datasource. This is a simple crystal report which runs and opens correctly within crystal reports itself. However...
  2. bunmiA

    create table query

    For the benefit of Tim and others who were helping with this thread. I have found a way around the problem. I am calling the sql query as a file (not a stored proc), (this means the query never needs to go to the master database), from a batch job. The batch job sets up the default database as...
  3. bunmiA

    create table query

    Thanks Tim...I've ammended it a bit, so I no longer get the ntext error... Here is the actual code... and the new error declare @vcdbname varchar(14), @sql_command1 varchar(18), @sql_command2 varchar(8000), @sql_command3 varchar(8000) set @vcdbname = 'offline'...
  4. bunmiA

    create table query

    Thanks Tim.... I get the following error Implicit conversion from data type ntext to varchar is not allowed. Use the CONVERT function to run this query.?>?
  5. bunmiA

    dynamic sql ??????

    I have a problem trying to run dynamic sql<>? when running the following query.. 'create ' + @dbname + '..tablename etc. this is all run as dynamic sql. The problem I am having is, the table being created is more than 8000 characters long...(defined as a sql command). The table has over 200...
  6. bunmiA

    create table query

    Thanks karl... but this doesnt work... I have found a work around which is to run the query with the db name i.e. 'create ' + @dbname + '..tablename etc. this is all run as dynamic sql. The problem I am having is, the table being created is more than 8000 characters long...(defined as a sql...
  7. bunmiA

    create table query

    I am writing a series of sql queries which go thru the following steps. 1. create the data base using a date extension.. 2. create a number of tables in the database created in step 1 3. populate the tables created in step 2 The problem I keep having is, even when I try to create the tables...
  8. bunmiA

    Delete Query

    I'm trying to delete rows from a database table using a stored procedure. Unfortunately, I the transaction log keeps filling up. I think I should be able to delete successfully in batches of 50,000. How do I do this within a stored procedure... The only thing I'm sure about is I use a while...
  9. bunmiA

    dynamic sql query (maximum length reached)

    I have created a sql query which executes another sql query within it. Unfortunately the query within is quite long and seems to exceed the 8000 limit for varchar. Does anyone have any ideas on how I can can execute this query... unfortunately, I can't split the query.. I am using a table which...
  10. bunmiA

    maximum length reached using varchar?

    I am running a dynamic sql query which I have declared as varchar(8000). The query is longer than 8000 characters long. Does anyone have any ideas of how I can code this. Thanks Bunmi
  11. bunmiA

    dynamic sql

    Thanks Tim...
  12. bunmiA

    dynamic sql

    thanks Tim... I have used the code below as I dont need the quotes.... however.. I'm still having trouble displaying @set!!!!!!... any ideas.. (I've commented @set out so that the query works) declare @scomm1 nvarchar(100), @set nvarchar(80) select @set = 'show' select @scomm1 = N'...
  13. bunmiA

    Remove leading zero's on an INT datatype

    good point... but you could replace the first letter doing this REPLACE(<fieldname>,left(<fieldname>,1),'') havent tested it... but it should work
  14. bunmiA

    dynamic sql

    Thanks Pattycake.... I deceided to go for your solution as it will help me to achieve what I need best. However Could I add a declared variable in as below?? declare @scomm1 nvarchar(90), @set char (20) set @set = 'showme' select @scomm1 = N'print '+ '''no entry'' + '','' + ''no...
  15. bunmiA

    Remove leading zero's on an INT datatype

    1) change these fields to 'char' fields using 'convert' 2)find what rows have them... you have been able to achieve this. 3) use REPLACE REPLACE(<fieldname>,'0','') 4) change field back to int using 'convert'

Part and Inventory Search

Back
Top