• Home
  • Categories
  • Tags
  • Pricing
  • Submit
  1. Home
  2. Sdks & Libraries
  3. pgvector-pascal

pgvector-pascal

Pascal bindings and examples for pgvector, supporting PostgreSQL-powered vector search from Pascal applications.

🌐Visit Website

About this tool


title: pgvector-pascal slug: pgvector-pascal brand: pgvector category: sdks-libraries tags:

  • sdk
  • pgvector
  • vector-store source_url: https://github.com/pgvector/pgvector-pascal images:
  • https://opengraph.githubassets.com/1/pgvector/pgvector-pascal

Overview

pgvector-pascal provides Pascal examples and bindings for using the pgvector PostgreSQL extension, enabling vector similarity search from Pascal applications. It currently supports the SQLDB database library from Free Pascal.

Features

  • Pascal bindings for pgvector

    • Demonstrates how to use PostgreSQL’s vector type from Pascal code
    • Integrates with the pgvector extension for vector similarity search
  • SQLDB support

    • Works with Free Pascal’s SQLDB library
    • Uses TSQLQuery (or equivalent) to execute SQL with vector types and parameters
  • Extension setup

    • Example code to enable the pgvector extension:
      CREATE EXTENSION IF NOT EXISTS vector
    • Shows how to run this via Query.SQL.Text and Query.ExecSQL
  • Schema definition with vector columns

    • Example table creation with a vector column:
      CREATE TABLE items (id bigserial PRIMARY KEY, embedding vector(3))
  • Inserting vectors from Pascal

    • Parameterized insert statements using Pascal string parameters cast to vector type
    • Demonstrates inserting multiple vector rows in one statement:
      INSERT INTO items (embedding) VALUES ((:embedding1)::vector), ((:embedding2)::vector)
  • Nearest neighbor search

    • Example query ordering by vector distance:
      SELECT * FROM items ORDER BY embedding <-> (:embedding)::vector LIMIT 5
    • Shows how to bind query parameters and iterate over result rows in Pascal
  • Approximate vector indexing

    • Examples of creating HNSW index:
      CREATE INDEX ON items USING hnsw (embedding vector_l2_ops)
    • Examples of creating IVFFlat index with configuration:
      CREATE INDEX ON items USING ivfflat (embedding vector_l2_ops) WITH (lists = 100)
  • Multiple distance metrics

    • Notes on choosing operator classes for different similarity metrics:
      • vector_l2_ops for Euclidean (L2) distance
      • vector_ip_ops for inner product
      • vector_cosine_ops for cosine distance
  • Runnable example program

    • Repository includes a complete example (example.pp) showing end-to-end usage:
      extension creation, table creation, inserts, search, and iteration over results
  • Development and testing setup

    • Example commands to clone and run:
      • git clone https://github.com/pgvector/pgvector-pascal.git
      • cd pgvector-pascal
      • createdb pgvector_pascal_test
      • fpc example.pp and ./example
    • Instructions for specifying the path to libpq by symlinking libpq.dylib when needed

Usage

  • Install and enable pgvector in PostgreSQL.
  • Use SQLDB in a Free Pascal application to:
    • Enable the extension (CREATE EXTENSION IF NOT EXISTS vector).
    • Create tables with vector(n) columns.
    • Insert vectors as strings cast to vector type via parameters.
    • Run similarity queries with <-> and limit results.
    • Add HNSW or IVFFlat indexes for approximate nearest neighbor search.

Pricing

  • Not specified in the provided content (GitHub-hosted example/binding, typically open source).
Surveys

Loading more......

Information

Websitegithub.com
PublishedDec 30, 2025

Categories

1 Item
Sdks & Libraries

Tags

3 Items
#SDK
#pgvector
#vector store

Similar Products

6 result(s)
pgvector-cobol

COBOL bindings and examples for pgvector, letting legacy COBOL systems interact with PostgreSQL as a vector database.

pgvector-crystal

Crystal language client for pgvector, providing idiomatic Crystal access to vector operations in PostgreSQL.

pgvector-dotnet

.NET (C#, F#, Visual Basic) library for pgvector that exposes vector storage and similarity queries on PostgreSQL to .NET applications.

pgvector-elixir

Elixir wrapper and examples for pgvector, integrating PostgreSQL-based vector search into Elixir ecosystems like Phoenix.

pgvector-erlang

Erlang client and examples for pgvector, providing tools to run vector operations against PostgreSQL from Erlang systems.

pgvector-gleam

Gleam language client and examples for pgvector, allowing Gleam applications to perform vector similarity search using PostgreSQL.

Built with
Ever Works
Ever Works

Connect with us

Stay Updated

Get the latest updates and exclusive content delivered to your inbox.

Product

  • Categories
  • Tags
  • Pricing
  • Help

Clients

  • Sign In
  • Register
  • Forgot password?

Company

  • About Us
  • Admin
  • Sitemap

Resources

  • Blog
  • Submit
  • API Documentation
All product names, logos, and brands are the property of their respective owners. All company, product, and service names used in this repository, related repositories, and associated websites are for identification purposes only. The use of these names, logos, and brands does not imply endorsement, affiliation, or sponsorship. This directory may include content generated by artificial intelligence.
Copyright © 2025 Acme. All rights reserved.·Terms of Service·Privacy Policy·Cookies