7,494 Archived Topics

Remove Filter
Member Avatar for
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 …

Databases microsoft mssql sql
Member Avatar for judithSampathwa
0
189
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 …

Databases mssql
Member Avatar for jovillanuev
0
121
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
135
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, …

Databases mssql sql
Member Avatar for urtrivedi
0
268
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 …

Databases mssql
Member Avatar for prit005
0
193
Member Avatar for geekme

After installing xampp, when i try to stop mysql and apache for restart it does not start.It gives error: mysql can not be stopped.Busy!Please help.

Databases apache mysql
Member Avatar for linuxaomi
0
140
Member Avatar for siabenie

Hi all, I like to rename my table's column. My table name is: utf8_Alter Field: Branch In the Branch field I have few columns name I tried to change the name with this query: But it didn't work. [CODE] ALTER TABLE `utf8_Alter` CHANGE `ゴルダーズグリーン` `ーン ノースロンドン` varchar( 64 ) MySQL …

Databases mysql
Member Avatar for smantscheff
0
152
Member Avatar for end3r

Hi, As the title states, I have a query that I use to concatenate all the rows into a single string and I use the XMLTransform method to accomplish that but I still need to add a new line separator within the XML string and so far I didn't find …

Databases oracle sql xml
Member Avatar for end3r
0
869
Member Avatar for michael.pilapil

Greetings, I am doing a project that will migrate sybase central to oracle with the used of oracle sql developer, and when im trying to add new connection in sql developer that will connect my sybase when i try the TEST button its status is success but when i retrieving …

Databases oracle
Member Avatar for michael.pilapil
0
283
Member Avatar for Sahilsahni

hi, since i have shifted my host these weird characters showed up on website! "ââ" i checked database, they are as it is written there. so when i call something through query they showed up too makes it worse, removing them manually is quite difficult. so please if anyone could …

Databases mysql
Member Avatar for smantscheff
0
154
Member Avatar for osm1987

Hello everyone, I have to query a table according to the current item being fetched in the select statement. What I meant, I want to form the name of the table and query it on runtime. For example, there is an item that comes from items table and it has …

Databases mysql
Member Avatar for debasisdas
0
122
Member Avatar for lifeworks

Hi I have a table storing time-sheet data, including a start & end time. I've set those fields as 'TIME' format, and tried doing the following calculation [code] SELECT SUM(log_end - log_start) AS timetotal FROM time_logs WHERE log_client = 'ECDC' [/code] It returned an integer, which doesn't correspond with any …

Databases mysql
Member Avatar for smantscheff
0
147
Member Avatar for timhysniu

Hi there, My knowledge on query optimization ends here. I am stuck! My table with following structure has more than 1 million records. CREATE TABLE `dreambank`.`db_ip_data_buffer` ( `ip_from` bigint(20) unsigned NOT NULL default '0', `ip_to` bigint(20) unsigned NOT NULL default '0', `country_code` varchar(2) default NULL, `country_name` varchar(64) default NULL, `region_name` …

Databases mysql
Member Avatar for gypsywitchcraft
0
209
Member Avatar for chandimak

I have a monthly fee collecting table. I need to store year and month only for that purpose. For example just like to store, John has done the payment for 2010 July. I thought of using a DATE field for this. I can store the year and month with valid …

Databases
Member Avatar for pclfw
0
129
Member Avatar for Arjun_Sarankulu

Update spot_price set location = ‘PATAN’ where symbol = ‘CASTORP’ and polling_date between ‘20110730’ and ‘20110806’ Giving sql syntax error. Same query i am using to update another table in sqlserver its working but not in mysql

Databases mysql
Member Avatar for Arjun_Sarankulu
0
116
Member Avatar for yumyam09

I'm thinking a databases that have scheduled time and date and if the computer time have been match to the scheduled time on the databases the other computer will be automatically shutdown

Databases mysql
Member Avatar for yumyam09
0
91
Member Avatar for Tunnleram

I'm missing something stupid so I need another set of eyes. I have a session value set that's a group concat of a few ids and I want to check to see if an id found by a query is in that group concat. The group concat variable is $session_unitidgrouping …

Databases mysql session
Member Avatar for urtrivedi
0
186
Member Avatar for mrhankey

hi, looking for some tips, using dreamweaver as my tool and wondering if someone could help. i basically have 2 tables. 1 which is partsused and the other stocklevels. the stocklevels contains stock details and also if it is in the van or unit. on my page i have an …

Databases mysql
Member Avatar for facarroll
0
1K
Member Avatar for hari_kiran

hello...i just installed oracle 10g in my pc but i dint get username and password for sql*plus......plz help me

Databases oracle sql
Member Avatar for abhay yadav
0
174
Member Avatar for adarshcu

[CODE] insert into AUDIT_TABLE( "TIMESTAMP", AUDITCATEGORY, USERID, AUDIT_XML, "AUDITID", "SOURCE", "ROLE", EVENT_ID, EVENT_DATA, TYPE_OF_APPLICATION) select CURRENT_TIMESTAMP, AUDITCATEGORY, USERID, AUDIT_XML, (SELECT MAX(AUDITID)+1 FROM AUDIT_TABLE), dummyNumber||i, "ROLE", EVENT_ID, EVENT_DATA, TYPE_OF_APPLICATION from AUDIT_TABLE where "SOURCE"='1312171509321'; [/CODE] Hi, Above is a part of my stored procedure , I'm trying to create test data for …

Databases oracle
Member Avatar for adarshcu
0
202
Member Avatar for karunakar reddy

create or replace [CODE]PACKAGE BODY employee_details AS PROCEDURE INSERT_ROW ( P_EMPNO IN NUMBER , P_ENAME IN VARCHAR2 , P_MGR IN VARCHAR2 , P_SAL IN NUMBER, P_DEPTNO IN NUMBER, P_COMM IN NUMBER, P_HIREDATE IN VARCHAR2, P_JOB IN VARCHAR2, P_error_message OUT VARCHAR2 ) is l_EMPNO NUMBER; l_object_name VARCHAR2(60) := 'employee_details.INSERT_ROW'; BEGIN te_trace('Entered …

Databases oracle
Member Avatar for hfx642
0
658
Member Avatar for vinaysrk919

it is highly recommended........that tell me exact difference between storedprocedure and trigger

Databases oracle
Member Avatar for hfx642
0
81
Member Avatar for Mr.Ram

Hi, how can we reduce the time of query execution time? I m using mysql. I have to execute one query which select data from lot of tables . It takes more time to execute. Please give me good suggestion for this.......

Databases mysql
Member Avatar for mwasif
0
803
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 …

Databases mssql
Member Avatar for Netcode
0
153
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 …

Databases mssql
Member Avatar for adam_k
0
153
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.

Databases mssql
Member Avatar for Ichcha
0
115
Member Avatar for Deathmachine

I restart a project of mine which use mysql, I used xampp in the past to test the code on the mysql server so I update to lasted version but a piece of code that is identical and was working, I now get an error in [U]the class check in …

Databases mysql
Member Avatar for Deathmachine
0
168
Member Avatar for RobotFX

I hope I can explain this. I have a table which contains a field named ID. This is set as PRIMARY. Because users registered on my site and after that deleted their accounts (so a lot of rows got deleted, too) the table rows now are jumping, for example, from …

Databases mysql
Member Avatar for debasisdas
0
89
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, …

Databases mssql
Member Avatar for mOrloff
0
169
Member Avatar for nohal.surya

Q--> i have a [U]employee[/U] table which cantain following field (eid,enm,salry,did) and i need a list which has employeies complete information whose get minimum saler in each department *** only single list cantain all employee info whose get minimum salry

Databases microsoft-access
Member Avatar for adam_k
0
154
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]

Databases mssql
Member Avatar for BitBlt
0
122
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 …

Databases mssql
Member Avatar for mOrloff
0
164
Member Avatar for bluetoot

Hello! please i need help with this,after sumiting my form i get this error message on line 111 any help i will appreciate, thx [CODE]<?php session_start(); include("../Connections/recruit.php"); echo "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?".">"; //check certification $certification = $HTTP_POST_VARS['certification']; if($certification != "accept") { echo(" Your application has been terminated as a result of …

Member Avatar for satyajit das
0
400
Member Avatar for facarroll

I have the following code. [CODE]$result = mysql_query("SELECT * FROM topics LEFT JOIN quiz ON topics.managerId = quiz.managerId WHERE quiz.userId = '$userId' AND userId= '$userId' AND $egroup = 1 GROUP BY topics.title")or die(mysql_error()); while ($row = mysql_fetch_array($result)){ echo "{$row['quizId']} <br />\n"; echo "{$row['title']} <br />\n"; echo "{$row['passState']} <br />\n"; } …

Databases display mysql
Member Avatar for Mikav6
0
113
Member Avatar for Deathmachine

I was wondering if anyone could point me what coding feature I'm talking about that can fulfill this role. - So I need to update data values from many users at the same time at a specific X amounts of time or specific hours of the day. What programing process …

Databases mysql
Member Avatar for Deathmachine
0
81
Member Avatar for minart

Hi, Hoping someone can help with a query I'm stuck on. I've got a field (sm_contact1number) containing phone numbers. Some of the data has been imported via Excel and its stripped some of the 0's out of the start of telephone numbers, so 0121 3324234 now looks like 121 3324234.. …

Databases mysql
Member Avatar for minart
0
164
Member Avatar for banmikko

I need some help regarding pagination. whenever i searched for a record, the pagination doesnt work but it still show the results. here are my codes index.php [CODE] <html> <head> <title>Paginating Your Data with AJAX and Awesome PHP Pagination Class</title> <form action="index.php" method="post" name="searchdb" id="searchdb"> <table> <tr> <td><tr> <input type="text" …

Member Avatar for debasisdas
0
156
Member Avatar for alenD

Hi, When a SELECT query is executed does MySQL store the resultset in some table? If it does, is there a way to find out that table and access it later before the session is closed? thanks,

Databases mysql session
Member Avatar for b89smith
0
105
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 ?

Databases mssql sql
Member Avatar for ChrisHunter
0
154
Member Avatar for kelvinnvl

I've to design a database for a tuition centre. Here is some business rules for it: - A centre has many student (1-m) - A centre has many teacher (1-m) - A centre offer one or more subjects (1-m) - A teacher teaches one or more subjects and a subject …

Databases database-design
Member Avatar for kelvinnvl
0
2K
Member Avatar for bigfixcat

Hi Everyone, this my first time. My question is how can I locate a non-ascii character in a string/field? Thanks, C

Databases mysql
Member Avatar for smantscheff
0
39
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

Databases mssql
Member Avatar for prit005
0
94
Member Avatar for blogger371

Hello everyone. Please somebody teach me how to setup mysql database. I have register a free domain for social bookmark website. But I found problems when making database. Please teach me step-by-step to create bookmark website database. Ohya, I use Pligg free software for social bookmark site. Thank you before. …

Databases mysql
Member Avatar for blogger371
0
152
Member Avatar for cobberas

Hi folks I have several JPEG thumbnail images in a database and need to select particular ones, stitch them together and post them into single cell in the table on a website. I've created the following query: [CODE]SELECT s.Set_Code, t.Mimetype, GROUP_CONCAT(t.Image SEPARATOR '<&nbsp\;>') AS 'Image' FROM Thumbnails t INNER JOIN …

Databases image mysql
Member Avatar for cobberas
0
1,000
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. …

Databases mssql
Member Avatar for arsheena.alam
0
200
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 …

Databases mssql
Member Avatar for jovillanuev
0
59
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 …

Databases mssql sql
Member Avatar for Ezzaral
0
84
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 …

Databases mssql
Member Avatar for MrCapuchino
0
109
Member Avatar for Dani

I have a somewhat complicated select query which returns, in part, the following resultset (as an example): [code=text] threadid views -------- ----- 1 5 1 5 2 10 3 15 4 10 [/code] If I were to do the following select: [code]COUNT (DISTINCT threadid), SUM (DISTINCT views)[/code] then it would …

Databases mysql
Member Avatar for Perez_Bottoms
0
15K
Member Avatar for Buffalo101

Hello, I need to create ER + relational models. I've came across Embarcadero Studio Data architect, but I'm having some trouble using it. What's the problem? I want the bottom table (PunctLucruActivitate) IDFirma to be in a relationship with IDFirma from the left table (PunctLucru). It won't let me do …

Databases
Member Avatar for BitBlt
0
104

The End.