【问题标题】:Synonyms in hyperfilesql and reserved keyword userhyperfilesql 中的同义词和保留关键字 user
【发布时间】:2016-02-16 15:53:59
【问题描述】:

如何在HyperFileSQL 中创建同义词?

我有一个名为USER 的表,我无法通过ODBC 访问它。我不能重命名它,所以我想为它创建一个同义词。我该怎么做?

【问题讨论】:

  • 尝试将其包裹在 [ ] 中。这可能会为您逃脱。

标签: database synonym tablename hyperfilesql


【解决方案1】:

要创建同义词,请使用此函数HAlias()

// Create an alias for the ORDERS file
// (Syntax available from version 19)
Orders2013 is Data Source <description=Orders>
IF HAlias(Orders, Orders2013) = True THEN
// ORDERS2013 can now be used in the processes
// It behaves the same way as 
// the ORDERS file described in the analysis.
// Modify the directory
HChangeDir(Orders2013, "D:\SalesMgt\Archive2013")
// Modify the name
HChangeName(Orders2013, "Orders")
HOpen(Orders2013)
... 
// Processes on the Orders2013 file
...
END
// Cancel the alias
HCancelAlias(Orders)

【讨论】:

  • 我只是想访问 USER 表。由于 USER 是一个关键字,我无法通过 ODBC 访问数据库。我安装了 ODBC,它适用于其他表...
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2016-07-11
  • 1970-01-01
  • 2022-02-26
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多