2,736 Topics

Member Avatar for
Member Avatar for dhfg

I am using SQL Server 2008. I have data from SQL like this. [CODE] ID ID2 PartNo -- ---- ---- 75 23921 DENT 75 26145 PLGD 75 26145 PRRP 75 26145 SIST 75 57290 PRMD 75 57290 abc 75 57290 def 75 57290 ghi 75 57290 jkl [/CODE] I need …

Member Avatar for Netcode
0
115
Member Avatar for azamsalam

I am using SQL Server 2005. I have a data from SQL like this. ID ID2 PartNo 75 23921 DENT 75 26145 PLGD 75 26145 PRRP 75 26145 SIST 75 57290 PRMD 75 57290 abc 75 57290 def 75 57290 ghi 75 57290 jkl I need an output like this. …

Member Avatar for dhfg
0
2K
Member Avatar for harishbansal90

Hi I have [B]Windows 7 Home Premium SP-1, 64-bit[/B] version on my PC. I want to install SQL Server either 2oo5 or 2008. but i am unable to install this. Error: [I]OS Incompatibility[/I] Pls Reply: Thank U

Member Avatar for sknake
0
452
Member Avatar for dips10

SELECT * INTO NewTable FROM existingdb.dbo.existingtable; I am executing this query but it is showing me the error as undeclared variable:Quanti (as quanti is my NewTable)

Member Avatar for Netcode
0
86
Member Avatar for munna_001

hi i have to search based on opening and closing times of shops. e.g. opening time of one is from 9 am to 11 pm another can be 5 am to nextday 2 am. e.g of sample data below [CODE] ShopID open time close time shop1 10am 11pm shop2 6am …

Member Avatar for munna_001
0
155
Member Avatar for wrathyimp

Hi, I have a sql view below: [CODE] SELECT b.Stk AS secode, b.TktE AS Ticket, CAST(a.Last / 10 AS integer(10, 3)) AS Last, CASE WHEN CONVERT(integer, a.Last) <> 0 THEN (CONVERT(integer, a.Last) - CONVERT(integer, a.Ref)) / 10 ELSE (CONVERT(integer, a.Ref) - CONVERT(integer, a.Prev)) / 10 END AS Change, CAST(a.High / …

Member Avatar for pritaeas
0
174
Member Avatar for jovillanuev

Guys, Please take a look my script. my object here is to get the most recent date from table 2. what if the recent date from table 2 is less than the date from table 1? [CODE] Table1 Type-Date1 -------- 1-2011-07-16 2-2011-07-16 3-2011-07-10 4-2011-07-10 Table2 Type-Date2 -------- 1-2011-07-06 2-2011-07-07 3-2011-07-01 …

Member Avatar for Pgmer
0
100
Member Avatar for uva1102

Good Day Everyone.. i have two tables..how to read from one table1 to table2.. example.. Table1 with thousand over records various types of recurrance and due pattern. where ID = History_ID Table 1 ID Reccurance Duepattern 1 Monthly 10 2 Yearly 25 3 Monthly 15 4 Weekly 5 yearly 14 …

Member Avatar for BitBlt
0
106
Member Avatar for jovillanuev

Hi guys, Need you inputs on my query. I have an excel file which we have to upload weekly. They want me to make an application using SSRS (MS SQL) . To read the excel file from a certain folder And then make some data entry to inputs like date …

Member Avatar for jovillanuev
0
128
Member Avatar for judithSampathwa

hi there, i have a question with the address text box. i am coding in C#. at first user enters the counrty. and then he enters the zip code. the state should pop up. for eg: if 60333 comes the relevant state should come up in the textbox called state …

Member Avatar for judithSampathwa
0
146
Member Avatar for darkagn

Hi all, I am getting an error in my application that reads: Incorrect syntax near the keyword 'set' It only occurs in a database at a particular venue and only when the offending query/queries are run locally. I have restored the database on my PC and the queries run without …

Member Avatar for adam_k
0
121
Member Avatar for judithSampathwa

hi i have a question relating to date. i have a table in a database which has the start date of an employee. what i want to do is i need to know how many years have he been working. so i need to get the current date and substract …

Member Avatar for judithSampathwa
0
187
Member Avatar for raghujosh

I have a JAVA method that executes the following query to SQL server database SELECT [CHEMICAL_NAME],[CHEMI_UNIT],[PRICE],[VENDOR],[CATEGORY]FROM [RPS].[dbo].[Chemicals]where CATALOGNO = '" + catNo+"' ;"; Following are the column names of the database table CATALOGNO, CAS_NO, CHEMICAL_NAME, CHEMI_UNIT, PRICE, VENDOR, CATEGORY, I get the above mentioned error "com.microsoft.sqlserver.jdbc.SQLServerException: The column name CATALOGNO …

Member Avatar for debasisdas
0
150
Member Avatar for jovillanuev

Hi Expert, Guys, i need your help on how to do a script calculating the totalDays using the formula (see below). i have to calculate the totaldays based on different Supplier and Rtype and also if the totalday is less than the warranty period i have to indicate it as …

Member Avatar for jovillanuev
0
119
Member Avatar for speak2ab

I am trying to connect to crystal report from Visual Studio 2010 but i realised my SQL database should have SQL authentication (i.e requires user and password) instead of windows (which was assigned by default). I have tried several approaches to achieve this without luck. Will appreciate some help.

Member Avatar for speak2ab
0
130
Member Avatar for Mangesh G

I have written an SQL query to return the total quantity of products ordered and total price. The query returns a result for each order in the range I have specified.Please find attached the output i am getting. the desired output i want is as follows: (year,productcode, productname, orders, quantity, …

Member Avatar for urtrivedi
0
257
Member Avatar for Tank50

Hi In my office there is an application ,and database is Sql server 2000.Using ODBC connection application connect to database.Recently database move into sql server 2005.Now application is not working,Its generate error message error message is "Connection failed".I tested the ODBC connection its okay. *I dont know what is language …

Member Avatar for prit005
0
188
Member Avatar for pclfw

I was asked a question a few days ago that I cannot easily answer. "Why don't we put all of our small application databases into a single database?" Well, There's nothing really stopping us. All of our small apps were developed in house so we don't have any problems with …

Member Avatar for Netcode
0
152
Member Avatar for Ichcha

the following gets first date of the week [CODE]DECLARE @Year SMALLINT = 2011 ;WITH cteSource(firstdate) AS ( SELECT CONVERT(varchar(50), DATEADD(DAY, 7 * v.Number, o.Origin), 101) AS firstdate FROM ( SELECT DATEADD(DAY, DATEDIFF(DAY, '18991230', STR(@Year, 4, 0) + '0101') / 7 * 7, '18991230') ) AS o(origin) INNER JOIN master.dbo.spt_values AS …

Member Avatar for adam_k
0
150
Member Avatar for Ichcha

[CODE] set datefirst 6 datepart(wk,'2011-01-12') [/CODE] yields 2. I would like to derive 2011-01-08 from this number. please help.thanks in advance.

Member Avatar for Ichcha
0
113
Member Avatar for mOrloff

I'm connecting to the DB with LibreOffice Base, and initially forgot that this [I]isn't[/I] a MySQL db [COLOR=SlateGray](it's our only non-mysql db)[/COLOR], so I have to say thanks to those from the other forum who helped get me started when I mis-posted. Anyhow, here's what I've got: [CODE]SELECT DISTINCT c.primaryemailaddress, …

Member Avatar for mOrloff
0
168
Member Avatar for PS189

Hi all, Batchdate comes in as string format (07/07/2011). I tried but for some reason am not getting any results. Any ideas? [CODE]ALTER PROCEDURE dbo.CouponReportbyScheme ( @BatchDate varchar(20) ) AS declare @myDate datetime select @myDate = convert( datetime, @BatchDate) Select * from Coupons where CouponGenerationDate=@myDate [/CODE]

Member Avatar for BitBlt
0
119
Member Avatar for mOrloff

I'm trying to populate a temp table, and I'm getting this error [INDENT][COLOR="Red"]Msg 8152, Level 16, State 14, Line 1 String or binary data would be truncated. The statement has been terminated.[/COLOR][/INDENT] Hmmmm ... here's what I'm trying. I created two temp tables and populated #emails from a spreadsheet (text …

Member Avatar for mOrloff
0
162
Member Avatar for zebnoon

Hello to all, I have installed SQL Server 2005 on windows xp . Please tell me how can i create new SQL database ?

Member Avatar for ChrisHunter
0
152
Member Avatar for Red_Indian

Hi, I have 20 rows in a table and I want to update 10 of them only. I am using MS SQL. Any ideas please. Cheers

Member Avatar for prit005
0
91
Member Avatar for shraddha.sawant

I hve created one procedure in oracle which is used as a dataset 1 in SSRS in oracle procedure we created one table which is used in sql server query as a dataset 2. but after click on refresh button it gives proper resultset. can we get proper data without …

0
67
Member Avatar for arsheena.alam

Hi, I have a table with more than 3000 records. I need to replace a particular string of all the rows wid some other string But when i am using replace function Its only replacing half of the rows of the table while the other half are not getting replaced. …

Member Avatar for arsheena.alam
0
180
Member Avatar for jovillanuev

Hi Guys, I have created a manual SSRS Report. when i click the layout tab it display report layout then i drag the fields from report datasets. i want to set my fields into Table details and i want to insert group but this function is missing or hide. i …

Member Avatar for jovillanuev
0
57
Member Avatar for t3chpr0digy

Hello, I have a SQL database that I am trying to run and narrow it down quite a bit. The database is for a calendar, and for a school district, on the main district homepage, I want to display events from all four high schools, but only the NEXT one …

Member Avatar for Ezzaral
0
82
Member Avatar for MrCapuchino

Hi, I want to implement a voting system in my web page. What I want to do is give a user 1 point per day so they can give that point to other users but after they give their point they have to wait until the next day to have …

Member Avatar for MrCapuchino
0
107

The End.