Questions tagged [sybase]

Sybase, a subsidiary of SAP, produces a variety of data management products. For their flagship RDBMS, Adaptive Server Enterprise, please use [sybase-ase]. For Adaptive Server Anywhere versions 6-9, use [sybase-asa]. For ASA v10 and above, use [sqlanywhere]. For the columnar data warehouse IQ, please use [sap-iq]

Sybase, now a subsidiary of SAP, was the first company to put a client/server relational database on the market.

Early versions of Microsoft SQL Server were based on Adaptive Server Enterprise, Sybase's flagship RDBMS.

Other popular Sybase products include:

  • IQ for data warehouse and big data applications
  • Adaptive Server Anywhere (ASA), an RDBMS for mobile and lightweight deployments
  • Sybase Unwired Platform (SUP) for developing mobile, data driven applications
  • Afaria for enterprise mobile device management
  • Replication Server for database replication

SAP has fully integrated the Sybase products into it's current offerings, and has dropped the Sybase name on all new product releases.

3158 questions
425
votes
23 answers

Cannot insert explicit value for identity column in table 'table' when IDENTITY_INSERT is set to OFF

I have the below error when I execute the following script. What is the error about, and how it can be resolved? Insert table(OperationID,OpDescription,FilterID) values (20,'Hierachy Update',1) Error: Server: Msg 544, Level 16, State 1, Line…
Jaison
365
votes
6 answers

Convert INT to VARCHAR SQL

I am using Sybase and I am doing a select which returns me a column called "iftype", but its type is int and I need to convert into varchar. When I try to do the select without the convert function I get this error: Error code 257, SQL state 37000:…
Murilo
  • 4,081
  • 5
  • 17
  • 25
80
votes
19 answers

Difference between drop table and truncate table?

I have some tables that I build as a part of my report rollup. I don't need them afterwards at all. Someone mentioned to truncate them as it would be faster.
Brian G
  • 49,145
  • 57
  • 120
  • 139
60
votes
4 answers

Undefined symbols for architecture i386: "_deflate", referenced from PlatCompress(enumCompressOperation, CompressCookie*, void*, long) in libMo.a

I'm doing native iOS application using SUP.As per documentation; i have included the library and given the link path in Xcode. While building getting following error: Undefined symbols for architecture i386: "_deflate", referenced from: …
bapi
  • 1,747
  • 9
  • 30
  • 53
37
votes
12 answers

How to get list of values in GROUP_BY clause?

If I have data like this in a table id data -- ---- 1 1 1 2 1 3 2 4 2 5 3 6 3 4 How do I get results like this in a query (on sybase server)? id data -- ---- 1 1, 2, 3 2 4, 5 3 6, 4
Jagmal
  • 5,078
  • 9
  • 33
  • 34
30
votes
3 answers

Execution order of WHEN clauses in a CASE statement

Given the following body of a case statement: 1 WHEN r.code= '00' then 'A1' 2 WHEN r.code ='01' AND r.source = 'PXWeb' then 'A2' < 3 WHEN r.code ='0120' then 'A3' 4 WHEN r.code ='01' …
The Ghost
  • 611
  • 1
  • 6
  • 14
29
votes
12 answers

From a Sybase Database, how I can get table description ( field names and types)?

I have access to command line isql and I like to get Meta-Data of all the tables of a given database, possibly in a formatted file. How I can achieve that? Thanks.
aartist
  • 2,853
  • 3
  • 29
  • 28
27
votes
3 answers

How do I limit the amount of results returned in Sybase?

I need to query a Sybase database which has a lot of data in it, and would like to set a limit so the DB stops the query after 10 results. The key thing is performance, so it would be no use if it searched all results and then then returned the last…
Ryan
  • 273
  • 1
  • 3
  • 4
22
votes
3 answers

Get records from last hour

I have this query: SELECT Field1, OrderFor, Writeback, Actshipdate, Orderstatus, receivedate, receivetime FROM orderinfo, shippinginfo WHERE orderinfo.orderid = shippinginfo.orderid AND shippinginfo.custid = '37782' AND receivedate = …
JeffreyLazo
  • 689
  • 3
  • 11
  • 17
19
votes
4 answers

How to separate positive and negative numbers into their own columns?

I have a table with the following columns and data: activity_dt | activity_amt 2009-01-01 | -500 2009-01-01 | 750 Can I write a query that looks at the sign of activity_amt and puts it in the credits column if it's positive, and the debits…
Mike Sickler
  • 30,442
  • 17
  • 58
  • 89
18
votes
4 answers

How do Ilist tables based on column name in sybase?

How do I list all the tables in a database that contain a column with a given name?
heena
  • 181
  • 1
  • 1
  • 3
17
votes
4 answers

How to convert a string to a date in sybase

I need to specify a date value in a sybase where clause. For example: select * from data where dateVal < [THE DATE]
cmsherratt
  • 2,119
  • 3
  • 15
  • 13
16
votes
5 answers

What is the mysterious 'timestamp' datatype in Sybase?

I recently discovered a table in our Sybase database at work that uses a column of a type 'timestamp'. If I create a table using this mysterious timestamp datatype like this create table dropme ( foo timestamp, roo int null ) insert into…
Eric Johnson
  • 16,234
  • 10
  • 49
  • 59
15
votes
4 answers

What's the equivalent of "Show Tables" in SQSH

How can I get sqsh to tell me which tables are available?
rampion
  • 82,104
  • 41
  • 185
  • 301
15
votes
5 answers

Best practices for multithreaded processing of database records

I have a single process that queries a table for records where PROCESS_IND = 'N', does some processing, and then updates the PROCESS_IND to 'Y'. I'd like to allow for multiple instances of this process to run, but don't know what the best practices…
Mike Sickler
  • 30,442
  • 17
  • 58
  • 89
1
2 3
99 100